#include <iostream>
#include <string>
#include <unordered_map>
#include <vector>
#include <algorithm>
#include <queue>

using namespace std;

class Solution {
public:
    string kthLargestNumber(vector<string>& nums, int k) {
        auto cmp = [](string a, string b) -> bool {
            if (a.length() < b.length()) {
                return false;
            } else if (a.length() > b.length()) {
                return true;
            } else {
                return a > b;
            }
        };
        priority_queue<string, std::vector<string>, decltype(cmp)> priQue(cmp);
        for (const auto& num : nums) {
            priQue.push(num);
            if (priQue.size() > k) {
                priQue.pop();
            }
        }

        return priQue.top();
    }
};

int main()
{    
    return 0;
}